<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (version 1.7.0_09) on Sat Dec 29 12:31:15 CET 2012 -->
<meta http-equiv="Content-Type" content="text/html" charset="UTF-8">
<title>org.gephi.ranking.spi (gephi 0.8.2 API)</title>
<meta name="date" content="2012-12-29">
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="org.gephi.ranking.spi (gephi 0.8.2 API)";
    }
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!--   -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li class="navBarCell1Rev">Package</li>
<li>Class</li>
<li><a href="package-use.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/gephi/ranking/api/package-summary.html">Prev Package</a></li>
<li><a href="../../../../org/gephi/statistics/api/package-summary.html">Next Package</a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/gephi/ranking/spi/package-summary.html" target="_top">Frames</a></li>
<li><a href="package-summary.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_top");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<a name="skip-navbar_top">
<!--   -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<div class="header">
<h1 title="Package" class="title">Package&nbsp;org.gephi.ranking.spi</h1>
<div class="docSummary">
<div class="block">Interfaces for creating new rankings and transformer.</div>
</div>
<p>See:&nbsp;<a href="#package_description">Description</a></p>
</div>
<div class="contentContainer">
<ul class="blockList">
<li class="blockList">
<table class="packageSummary" border="0" cellpadding="3" cellspacing="0" summary="Interface Summary table, listing interfaces, and an explanation">
<caption><span>Interface Summary</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Interface</th>
<th class="colLast" scope="col">Description</th>
</tr>
<tbody>
<tr class="altColor">
<td class="colFirst"><a href="../../../../org/gephi/ranking/spi/RankingBuilder.html" title="interface in org.gephi.ranking.spi">RankingBuilder</a></td>
<td class="colLast">
<div class="block">Ranking builder, creating <code>Ranking</code> instances suitable to the given
 <a href="../../../../org/gephi/ranking/api/RankingModel.html" title="interface in org.gephi.ranking.api"><code>RankingModel</code></a>.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><a href="../../../../org/gephi/ranking/spi/TransformerBuilder.html" title="interface in org.gephi.ranking.spi">TransformerBuilder</a></td>
<td class="colLast">
<div class="block">Transformer builder, creating <code>Transformer</code> instances.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><a href="../../../../org/gephi/ranking/spi/TransformerUI.html" title="interface in org.gephi.ranking.spi">TransformerUI</a></td>
<td class="colLast">
<div class="block">Transformer user interface.</div>
</td>
</tr>
</tbody>
</table>
</li>
</ul>
<a name="package_description">
<!--   -->
</a>
<h2 title="Package org.gephi.ranking.spi Description">Package org.gephi.ranking.spi Description</h2>
<div class="block">Interfaces for creating new rankings and transformer. <code>RankingBuilder</code>
        feeds the list of available rankings. The default rankings include for
        instance 'Degree' or numerical attribute columns. Transformers apply for
        instance color or size transformation to objects.
        <h3>Create a new Transformer</h3>
        <ol><li>Create a new module and set <code>RankingAPI</code>, <code>GraphAPI</code>
                and <code>Lookup</code> as dependencies.</li>
            <li>Create a new builder class by implementing <code>TransformerBuilderr</code>,
            this class is basically a factory that will create the transformer on demand.</li>
            <li>Add <b>@ServiceProvider</b> annotation to your builder, that it can
                be found by the system. Set <code>TransformerBuilder</code> as the
                annotation parameter. You can also add a position to define the order
                your transformer should be displayed. Put 1000 to be displayed after
                the default one.</li>
            <li>Implement the <code>isTransformerForElement()</code> method. If your
                transformer manipulates both nodes and edges, return <code>true</code>
                when the element type is <code>Ranking.NODE_ELEMENT</code> or
                <code>Ranking.EDGE_ELEMENT</code>. If it manipulates only one element,
                restrict in consequences.</li>
            <li>Create a new class that implements <code>Transformer</code>. One can
                add a dependency to the RankingPlugin module and extends the
                <code>AbstractRanking</code>.</li>
            <li>Configure the Target type of you transformer. If your transformer works only
                with nodes, put <code>NodeData</code>, if it works only with edges, put
                <code>EdgeData</code>. If it works with both, put <code>Renderable</code> or
                <code>Attributable</code>. These are interfaces both nodes and edges implement.</li>
            <li>Implement the <code>transform()</code> method of the transformer.</li>
            <li>If the transformer needs an UI, create a new class that implements the
                <code>TransformerUI</code> interface. Add <b>@ServiceProvider</b> annotation
                to your class, that it can be found by the system. Set <code>TransformerUI</code>
                as the service annotation parameter.</li>
            <li>Configure the <code>isUIForTransformer()</code> to return <code>true</code> only
                when the given transformer is an instance of the Transformer you defined earlier.</li>
            <li>Implement a user interface and set the <code>getPanel()</code> method to return it.</li>
        </ol></div>
</div>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!--   -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li class="navBarCell1Rev">Package</li>
<li>Class</li>
<li><a href="package-use.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/gephi/ranking/api/package-summary.html">Prev Package</a></li>
<li><a href="../../../../org/gephi/statistics/api/package-summary.html">Next Package</a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/gephi/ranking/spi/package-summary.html" target="_top">Frames</a></li>
<li><a href="package-summary.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_bottom");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<a name="skip-navbar_bottom">
<!--   -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright &#169; 2007-2012 <a href="http://consortium.gephi.org">Gephi Consortium</a>. All Rights Reserved.</small></p>
</body>
</html>
